package com.ludaxun.mapapi.controller;


import com.ludaxun.mapapi.utils.R;
import com.ludaxun.mapapi.utils.interfaceS.MapCorrelation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/test")
public class textController {

    @Resource
    MapCorrelation mapCorrelation;

    @GetMapping("test")
    public R getTest(@RequestParam double lon1,@RequestParam double lat1,@RequestParam double re,@RequestParam double lon2,@RequestParam double lat2){



        return R.ok(mapCorrelation.ScopeCalculate(lon1,lat1,re, lon2,lat2));
    }

}
